package com.learn.algorithm.designpattern.builder;

import java.util.StringJoiner;

/**
 * @author wangxing
 * @version 2020/8/20 6:40 Administrator
 */
public class TempBean {
    public TempBean() {
    }
    Temp1B temp1B;
    Temp2B temp2B;
    Temp3B temp3B;

    public Temp1B getTemp1B() {
        return temp1B;
    }

    public void setTemp1B(Temp1B temp1B) {
        this.temp1B = temp1B;
    }

    public Temp2B getTemp2B() {
        return temp2B;
    }

    public void setTemp2B(Temp2B temp2B) {
        this.temp2B = temp2B;
    }

    public Temp3B getTemp3B() {
        return temp3B;
    }

    public void setTemp3B(Temp3B temp3B) {
        this.temp3B = temp3B;
    }

    @Override
    public String toString() {
        return new StringJoiner(", ", TempBean.class.getSimpleName() + "[", "]")
                .add("temp1B=" + temp1B)
                .add("temp2B=" + temp2B)
                .add("temp3B=" + temp3B)
                .toString();
    }
}
class Temp1B {
    private String s1,s2,s3;
    public Temp1B(String s1, String s2, String s3) {
        this.s1 = s1;
        this.s2 = s2;
        this.s3 = s3;
    }
    @Override
    public String toString() {
        return new StringJoiner(", ", Temp1B.class.getSimpleName() + "[", "]")
                .add("s1='" + s1 + "'")
                .add("s2='" + s2 + "'")
                .add("s3='" + s3 + "'")
                .toString();
    }
}

class Temp2B {
    private String s1,s2,s3;

    public Temp2B() {
    }

    @Override
    public String toString() {
        return new StringJoiner(", ", Temp2B.class.getSimpleName() + "[", "]")
                .add("s1='" + s1 + "'")
                .add("s2='" + s2 + "'")
                .add("s3='" + s3 + "'")
                .toString();
    }
}

class Temp3B {
    private String s1,s2,s3;

    public Temp3B() {
    }

    @Override
    public String toString() {
        return new StringJoiner(", ", Temp3B.class.getSimpleName() + "[", "]")
                .add("s1='" + s1 + "'")
                .add("s2='" + s2 + "'")
                .add("s3='" + s3 + "'")
                .toString();
    }
}
